package week9;
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;
//201621123068
interface CharacterStack {
    
    public Character push(Character item);

    public Character pop();

    public boolean empty();

}

class Stack implements CharacterStack {
    private List<Character> list;

    public Stack() {
        list = new ArrayList<Character>();
    }

    @Override
    public Character push(Character item) {
        if (item == null)
            return null;
        list.add(item);
        return item;
    }

    @Override
    public Character pop() {
        if (list.isEmpty())
            return null;
        return list.remove(list.size() - 1);
    }

    @Override
    public boolean empty() {
        if (list.isEmpty())
            return true;
        return false;
    }

}

public class Main201621123068 {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        Stack stack = new Stack();
        while(sc.hasNext())
        {
            String str = sc.next ();
            char mystr[] = str.toCharArray();
            for (int i = 0; i < str.length(); i++) {

                stack.push(mystr[i]);
            }

            for (int i = 0; i < str.length(); i++) {
                if(mystr[i] != stack.pop()) {
                    System.out.println("No");
                    break;
                }
            }
            if(stack.empty()){
                System.out.println("Yes");
            }
        }
    }
}